package com.chzc.fm.duotin.bean.channel;

import com.google.gson.Gson;
import com.google.gson.reflect.TypeToken;

import java.io.Serializable;
import java.lang.reflect.Type;
import java.util.ArrayList;
import java.util.List;

/**
 * Created by Administrator on 2016/6/24.
 */
public class AnchorSpecialItem implements Serializable {

    /**
     * id : 10913
     * name : 大盘
     */

    private int id;
    private String name;

    public static AnchorSpecialItem objectFromData(String str) {

        return new Gson().fromJson(str, AnchorSpecialItem.class);
    }

    public static List<AnchorSpecialItem> arrayAnchorItemFromData(String str) {

        Type listType = new TypeToken<ArrayList<AnchorSpecialItem>>() {
        }.getType();

        return new Gson().fromJson(str, listType);
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }
}
